﻿using JT808.Protocol.Attributes;
using JT808.Protocol.Formatters.MessageBodyFormatters;
using System;
using System.Collections.Generic;
using System.Text;

namespace JT808.Protocol.MessageBody
{

    /// <summary>
    /// 数据下行透传 ==》 设置胎压传感器 ID 和轮位绑定
    /// </summary>
    [JT808Formatter(typeof(JT808_0x8900_Bind_Formatter))]
    public class JT808_0x8900_Bind : JT808Bodies
    {
        /// <summary>
        /// 透传消息ID
        /// </summary>
        public byte passthroughID;

        /// <summary>
        /// 操作模式
        /// </summary>
        public byte operationType;

        /// <summary>
        /// 配置轮胎个数
        /// </summary>
        public byte tyreNumber;

        /// <summary>
        /// 配置参数
        /// </summary>
        public List<JT808_0x8900_Sensor> sensor;

    }

    public class JT808_0x8900_Sensor
    {
        /// <summary>
        /// 传感器Id
        /// </summary>
        public string sensor_Id;

        /// <summary>
        /// 托卡号
        /// </summary>
        public byte toca;

        /// <summary>
        /// 轮胎序号
        /// </summary>
        public byte tyreSerialNumber;
    }
}
